package cn.tutu.blockchain.filebak.dao;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import cn.tutu.blockchain.base.BaseDao;
import cn.tutu.blockchain.filebak.entity.Filebak;

@Mapper
public interface FilebakDao extends BaseDao<Filebak> {

	/**
	 * 在备份表中根据矿机ID找出该矿机已经备份过的文件
	 * 
	 * @param minemachineId
	 *            矿机ID
	 * @return
	 */
	List<String> findBakDoneByMacId(String minemachineId);

	void insertBatch(@Param("fileInfoList") List<String> fileInfoList, @Param("minemachineId") String minemachineId);

	List<Filebak> findByMacId(String minemachineId);

	void deleteByMacId(String minemachineId);

}
